<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>

<!DOCTYPE html>
<html>
<head>
<style type="text/css">
span1{
 font-family:微软雅黑 ;
 font-size: 20px;
 color: teal;
}
li1{
 font-family:宋体;
  font-size: 18px;
}
body{
 background-image: url("http://localhost:8080/my_term_project_xuanke/resource/image/changePW.png");
 background-size: cover;
}
span2{
font-family:华文中宋;
font-size: 18px;
color: white;
}
td{
margin-left: 30px;
font-family:黑体;
font-size: 20px;
}
li{
font-family:华文中宋;
font-size: 16px;
}
.scbtn1{
font-family:黑体;
font-size: 16px;
text-align: center;
background-color: red;
border: 10px;
color: white;
padding: 5px 10px;
display: inline-block;
}
</style>
<meta charset="UTF-8">
<title>修改学生密码</title>
<script>
	function validateForget(){
		var id=document.forms["forgetPW"]["Id"].value;
		var phone=document.forms["forgetPW"]["Phone"].value;
		var newpwd1=document.forms["forgetPW"]["newPwd1"].value;
		var newpwd2=document.forms["forgetPW"]["newPwd2"].value;
		
		if (id==""){
			 alert("请输入用户名!");
	         return false;
		}
		if(phone==""){
			 alert("请输入密保手机!");
	         return false;
		}
		if(newpwd1 != newpwd2){
			alert("两次密码输入不一致");
	        return false;
		}
	}
</script>
</head>
<body>
<div class="place">
    <span1>忘记密码</span1>
    <ul>
    <li1 style = "margin-left:0px;"><a href="http://localhost:8080/my_term_project_xuanke/login/login.jsp">首页</a></li1>
    </ul>
    </div>
	    <div>
	    <form method="POST" name="forgetPW" onsubmit="return validateForget()" action="http://localhost:8080/my_term_project_xuanke/loginServlet?action=forgetPW"><!--  -->
		    <table>
		    	<tr><td>&nbsp;&nbsp;&nbsp;账&nbsp;&nbsp;&nbsp; 号</td><td><input name="Id" placeholder="请输入你的账号" type="text" class="dfinput" /></td></tr>
		    	<tr><td>&nbsp;&nbsp;&nbsp;手机号码</td><td><input name="Phone" placeholder="请输入你绑定的手机号" type="text" class="dfinput" /></td></tr>
			    <tr><td>&nbsp;&nbsp;&nbsp;新 密 码 </td><td><input name="newPwd1"  type="password" class="dfinput" /></td></tr>
			    <tr><td>&nbsp;&nbsp;&nbsp;确&nbsp;&nbsp;&nbsp;  认</td><td><input name="newPwd2" type="password" class="dfinput" /></td></tr>    	 
		    
		    </table>
		    <ul>
			     <li><input type="radio" name="who" value="student" checked="checked">&nbsp;学生
					 <input type="radio" name="who" value="admin">&nbsp;管理员
				 </li>
				 <li2>	
		     	 <input name="" type="submit" class="scbtn1" value="修改密码" onclick="vatrdateForget()"/>
		     	 </li2>
		     </ul>
		    </form>
		    </div>
		    
	    <span2>开发员联系方式：TEl：1111111111</span2>

</body>
</html>